package com.i2works.smartluolong.utils.base;

/**
 * 消息枚举类
 *
 * @author Liu Yutao <koal@vip.qq.com>
 * @date 2016/1/30 21:39
 */

public enum MsgEnum {
    //    MOBILE_DEFAULT(null, null),
    SYSTEM_ERROR("-1", "系统错误，请联系管理员"),
    ACCESS_LOGIN_FAIL("0", "登录失败"),
    ACCESS_LOGIN_SUCCESS("0", "登录成功"),
    ACCESS_AUTHC_FAIL("0", "鉴权失败"),
    ACCESS_AUTHC_EXPTIME("0", "鉴权超时"),
    ACCESS_AUTHC_PARAMS_ERROR("0", "鉴权参数错误"),
    ACCESS_UNKNOW("0", "账号不存在"),
    ACCESS_REG_FAIL("0", "账号注册失败"),
    ACCESS_REG_SUCCESS("0", "账号注册成功"),
    ACCESS_INVALID("101", "账号已被停用"),
    ACCESS_ERROR("102", "账号或密码错误"),
    ACCESS_EMPTY("103", "账号或密码不能为空"),
    ACCESS_LOCKED("104", "密码输错次数达到上限，请30分钟后重试。"),
    ACCESS_USER_EMPTY("110", "账号格式错误"),
    ACCESS_USER_ERROR("111", "账号格式错误"),
    ACCESS_EMAIL_ERROR("112", "邮箱格式错误"),
    ACCESS_EMAIL_EMPTY("113", "邮箱不能为空"),
    ACCESS_PASSWORD_ERROR("114", "密码格式错误"),
    ACCESS_CONFIRMPASSWORD_ERROR("115", "两次密码不同"),
    ACCESS_PASSWORD_EMPTY("116", "密码不能为空"),
    ACCESS_USEREMAIL_EMPTY("117", "账号或邮箱不能为空"),
    ACCESS_USEREMAIL_KNOW("118", "账号或邮箱已存在"),
    ACCESS_USEREMAIL_NOKNOW("118", "账号或邮箱不存在"),
    ACCESS_USERPHOME_EMPTY("117", "账号或手机号不能为空"),
    ACCESS_PHOMEPASSWORD_EMPTY("117", "手机号或密码不能为空"),
    ACCESS_USERPHOME_KNOW("118", "账号或手机号已存在"),
    ACCESS_USERPHOME_NOKNOW("118", "账号或手机号不存在"),
    ACCESS_UPDATE_PASSWORD_SUCCESS("119", "密码修改成功"),
    ACCESS_UPDATE_PASSWORD_FAIL("119", "密码修改失败"),
    ACCESS_USERID_NULL("119", "用户编号为空"),
    ACCESS_AVATAR_NULL("119", "用户头像为空"),
    ACCESS_AVATAR_ERROR("119", "用户头像上传出错"),
    ACCESS_AVATAR_SUCCESS("119", "用户头像上传成功"),
    ACCESS_USER_KNOW("119", "账号已存在"),
    ACCESS_USER_NULL("119", "账号不能为空"),
    ACCESS_EMAIL_KNOW("120", "邮箱已存在"),
    ACCESS_EMAIL_NULL("120", "邮箱不能为空"),
    ACCESS_PHONE_KNOW("120", "手机号已存在"),
    ACCESS_PHONE_NOKNOW("120", "手机号不存在"),
    ACCESS_PHONE_NULL("120", "手机号不能为空"),
    ACCESS_TYPE_NULL("120", "用户类型不能为空"),
    ACCESS_AUTH_SUCCESS("120", "已完成信息认证"),
    ACCESS_AUTH_FAILED("120", "信息认证失败"),
    ACCESS_ID_NULL("120", "用户编号不能为空"),
    LOGIN_FAILED("120", "登录失败，请刷新本页面重试"),
    REGIST_FAILED("121", "注册失败，请刷新本页面重试"),
    RESERT_FAILED("122", "修改密码失败，请刷新本页面重试"),
    FORM_RESUBMIT_ERROR("123", "请勿重复提交"),
    SMS_PHONE_NULL("130", "接收短信的手机号为空"),
    SMS_PHONE_CODE_NULL("130", "验证码或手机号不能为空"),
    SMS_CODE_REPEAT("1101", "每个手机号60秒内仅能发送1次验证码。"),
    SMS_CODE_ERROR("1101", "短信验证码错误"),
    SMS_CODE_TIMEOUT("1102", "短信验证码已过期"),
    SMS_CODE_EMPTY("1102", "短信验证码不能为空"),
    SMS_CODE_PARAMS_ERROR("1104", "短信验证码参数错误"),
    SMS_CODE_SEND_ERROR("1103", "短信验证码发送失败"),
    SMS_CODE_SEND_SUCCESS("1104", "短信验证码发送成功"),
    SMS_INFORM_PARAMS_ERROR("1103", "短信参数错误"),
    SMS_INFORM_SEND_ERROR("1103", "短信发送失败"),
    SMS_INFORM_SEND_SUCCESS("1104", "短信发送成功"),
    VERIFY_ERROR("130", "验证码错误"),
    VERIFY_EMPTY("131", "验证码不能为空"),
    VERIFY_EMPTY_TIMEOUT("131", "验证码已过期，请刷新页面"),
    TOKEN_VERIFY_TIMEOUT("130", "验证已超时,请重新申请。"),
    TOKEN_VERIFY_ERROR("130", "验证错误"),
    TOKEN_VERIFY_EMPTY("131", "验证不能为空"),
    URL_VERIFY_TIMEOUT("132", "此链接已失效,请重新申请找回密码。"),
    RESET_PASSWORD_EMAIL_SUCCESS("132", "找回密码邮件已发送到：%s，请登录邮箱操作。"),
    RESET_PASSWORD_SUCCESS("133", "密码已修改为：%s，请妥善保管。"),
    RESET_EMAILL_SUCCESS("134", "邮箱已修改为：%s，请妥善保管。"),
    RESET_PASSWORD_EMAIL_ERROR("135", "账号验证失败，请输入正确的账号。"),
    STR_ENPTY("0", "%s不能为空。"),
    STR_REGEX_ERROR("0", "%s格式不正确。"),
    SAVE_ERROR("201", "保存失败！"),
    EDIT_ERROR("202", "编辑失败！"),
    FIND_ERROR("203", "查询失败！"),
    UPDATE_ERROR("204", "更新失败！"),
    STATUS_ERROR("205", "状态编辑失败！"),
    DELETE_ERROR("206", "信息删除失败！"),
    CHECK_TRUE("207", "信息已存在！"),
    CHECK_FALSE("208", "信息不存在！"),
    NOT_UPDATE_INFO("701", "未修改任何信息"),
    ATTRS_TIMEOUT("801", "参数超时,请重新申请"),
    ITEM_SUCCESS("801", "审核中，请勿重复提交"),
    ATTRS_ERROR("802", "参数错误"),
    ATTRS_EMPTY("803", "参数为空"),
    ATTRS_IS_USED("803", "所填信息已被占用"),
    ATTRS_IDCART_EMPTY("803", "身份证或营业执照照片必须上传"),
    FORCE_LOGOUT_MESSAGE("804", "你被强迫下线，因账号已在其他地方登录！"),
    UPLOAD_FILE_EMPTY("805", "上传文件为空！"),
    UPLOAD_FILE_ERROR("805", "上传文件错误！"),
    UPLOAD_FILE_SIZE_ERROR("805", "您上传的文件太大！"),
    UPLOAD_FILE_TYPE_ERROR("805", "请上传允许格式的文件！"),
    SEARCH_ERROR("805", "搜索结果出错！"),
    API_NOFONUD("-999", "api不存在");

    MsgEnum(String errorCode, String msg) {
        this.errorCode = errorCode;
        this.msg = msg;
    }

    private String errorCode;
    private String msg;

    public String getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
